<template>
  <div>
    我是测试1<v-btn @click="changeModal">切换dasd</v-btn
    ><v-btn @click="handlePost">掉接口</v-btn>
    <div class="text-center ma-2">
      <v-btn @click="snackbar = true"> Open Snackbar </v-btn>
      <v-snackbar v-model="snackbar" :top="true"
      :bottom="false"
      :left="false"
      :right="true" :style="{left:'10px',top:'10px'}" :location="'top right'"  :position="'absolute'" :timeout="100000" :absolute="true" position="sticky" :timer="true">
        1232131

        <template v-slot:actions>
          <v-btn color="pink" variant="text" @click="snackbar = false">
            Close
          </v-btn>
        </template>
      </v-snackbar>
    </div>
  </div>
</template>

<script lang="ts" setup>
import service from "@/api";
import test2 from "./test2.vue";
const shareStore = useShareStore();
const changeModal = () => {
  console.log();

  shareStore.openModal(test2, {
    title: "我是test2",

    cardAttr: {},
  });
};
const snackbar = ref<boolean>(false);
const handlePost = () => {
  snackbar.value = false;
  service.get(HttpMap.findAll);
};
</script>
